One simple and convenient way to achieve private communications is for groups of wireless devices to be organized into flexible networks that can accommodate changing members. Nodes of an ad hoc network may be mobile telephones, especially devices such as smartphones capable of both voice and data communication. Members of a group may wish to maintain their communications private, and may seek both to protect the content of their messages and the origin of their messages. Group members may wish to conceal both the fact that a message is coming from a particular node, and may also wish to conceal the fact that nodes belong to the group. Members of a group may encrypt their traffic using a shared key K, and may also anonymize a group identifier by using mechanisms such as a community pseudonym, not associated with any particular node.
It is known, however, that various mechanisms exist by which attackers attempt to identify the presence of group members. One such mechanism is a replay attack, identifying the presence in a local network of members of the private group. If a wireless device responds to a message from the group with an encrypted message of its own, it is highly likely that the responding device belongs to the group. An attacker who does not know the group key and cannot read encrypted messages may nevertheless attempt to identify group members by recording and rebroadcasting a valid query. Various mechanisms have been developed that are generally effective in defending against a query that is replayed in the same network in which it originated. One approach is limiting the number of times a node can respond to a query, such as one time. Another approach, which may be used together with the first, is to limit the validity time of a query. Nodes that have received a query, as will be the case if an attack is attempted in the same network, will fail to respond to the same query more than the specified number of times or outside the validity time of the query.